package com.fzshang.shopping.commen.bean;

import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.ToString;

/**
 * <p>
 * 销售
 * </p>
 *
 * @author 冯政尚
 * @since 2020-03-12
 */
@ToString
@ApiModel(value="Sale对象", description="销售")
public class Sale extends Model<Sale> {

    private static final long serialVersionUID = 1L;

    @TableId("id")
    private Long id;

    @ApiModelProperty(value = "微信openid")
    @TableField("openid")
    private String openid;

    @ApiModelProperty(value = "身份证")
    @TableField("id_number")
    private String idNumber;

    @ApiModelProperty(value = "正面")
    @TableField("positive")
    private String positive;

    @ApiModelProperty(value = "反面")
    @TableField("side")
    private String side;

    @ApiModelProperty(value = "入驻费")
    @TableField("money")
    private String money;

    @ApiModelProperty(value = "姓名")
    @TableField("name")
    private String name;

    @ApiModelProperty(value = "手机号")
    @TableField("phone")
    private String phone;

    @ApiModelProperty(value = "地址")
    @TableField("address")
    private String address;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    private Long createTime;

    @TableField(exist = false)
    private Double mm;

    @ApiModelProperty(value = "昵称")
    @TableField(exist = false)
    private byte[] nickName;

    @ApiModelProperty(value = "头像")
    @TableField(exist = false)
    private String userUrl;

    public String getUserUrl() {
        return userUrl;
    }

    public void setUserUrl(String userUrl) {
        this.userUrl = userUrl;
    }

    public String getNickName() {
        if(nickName==null){
            return null;
        }
        return new String(nickName);
    }

    public void setNickName(byte[] nickName) {
        this.nickName = nickName;
    }

    public Double getMm() {
        return mm;
    }

    public void setMm(Double mm) {
        this.mm = mm;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }
    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }
    public String getIdNumber() {
        return idNumber;
    }

    public void setIdNumber(String idNumber) {
        this.idNumber = idNumber;
    }
    public String getPositive() {
        return positive;
    }

    public void setPositive(String positive) {
        this.positive = positive;
    }
    public String getSide() {
        return side;
    }

    public void setSide(String side) {
        this.side = side;
    }
    public String getMoney() {
        return money;
    }

    public void setMoney(String money) {
        this.money = money;
    }
    public Long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Long createTime) {
        this.createTime = createTime;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "Sale{" +
            "id=" + id +
            ", openid=" + openid +
            ", idNumber=" + idNumber +
            ", positive=" + positive +
            ", side=" + side +
            ", money=" + money +
            ", createTime=" + createTime +
        "}";
    }
}
